﻿@model DotNetUniLodz.Models.Category

@{
    ViewBag.Title = "Edytuj artykuł " + Model.Category_name;
}
<div id="Content100">
    <h2>Edycja</h2>
    @using (Html.BeginForm())
    {
        @Html.AntiForgeryToken()
        @Html.ValidationSummary(true)

        <fieldset id="CreateItem">
            <legend>Edytuj kategorię</legend>

            @Html.HiddenFor(model => model.Category_id)
            <div class="editor-label">
                Nazwa kategorii
            </div>
            <div class="editor-field">
                @Html.EditorFor(model => model.Category_name)
                @Html.ValidationMessageFor(model => model.Category_name)
            </div>

            @*        <div class="editor-label">
            @Html.LabelFor(model => model.Category_parent, "Category2")
        </div>
        <div class="editor-field">
            @Html.DropDownList("Category_parent", String.Empty)
            @Html.ValidationMessageFor(model => model.Category_parent)
        </div>*@

            <p>
                <input type="submit" value="Zapisz" />
            </p>
        </fieldset>
    }
    <div>
        @Html.ActionLink("Powrót do listy kategorii", "Index", null, new { @class = "SuperLink" })
    </div>
</div>

@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}
